<template>
  <div id="app">
    
    <h1>根组件 {{title}}</h1>
    <input type="text" >
    <!-- <input type="text" :value='count' @input="changeCount($event.target.value)"> -->
    <add-item></add-item>
    <hr>
    <sub-item></sub-item>
  </div>
</template>

<script>

import AddItem from './components/add-item.vue'
import SubItem from './components/sub-item.vue'
import {mapState} from 'vuex'

export default {
  name: 'app',
  components: {
    AddItem,
    SubItem
  },
  computed:{
    ...mapState('setting',['title'])
  }
}
</script>

<style>
#app {
  width: 600px;
  margin: 20px auto;
  border: 3px solid #ccc;
  border-radius: 3px;
  padding: 10px;
}
</style>